<!-- el-select中获取额外参数 -->
<template>
  <div>
   <el-select v-model="value" placeholder="请选择" @change="handlerChange1">
    <el-option
      v-for="item in options"
      :key="item.value"
      :label="item.label"
      :value="item.value">
    </el-option>
  </el-select>

  </div>
</template>
<script>

export default {
  name: 'App',
  components: {

  },

  data() {
    return {
      options: [{
          value: '选项1',
          label: '黄金糕',
          id:1
        }, {
          value: '选项2',
          label: '双皮奶',
          id:2
        }, {
          value: '选项3',
          label: '蚵仔煎',
          id:3
        }, {
          value: '选项4',
          label: '龙须面',
          id:4
        }, {
          value: '选项5',
          label: '北京烤鸭',
          id:5
        }],
        value: ''
    }
  },

  mounted() {
    
  },

  methods: {
    handlerChange1(val) {
      console.log(val);
      const arr = this.options.filter(item => {
        return val === item.value
      });
      console.log(arr);
    }
  }
}
</script>

<style>
#app {
  height: 800px;
}
</style>